﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="allNews1.aspx.cs" Inherits="allNews1" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
</head>
<body>
    <form id="form1" runat="server">
    <div>
        <ul>
            <asp:DataList ID="DataList1" runat="server" Width="976px" Height="745px" BorderWidth="2px"
                CellPadding="2" CellSpacing="2" RepeatColumns="7" RepeatDirection="Vertical"
                BorderColor="#666666">
                <ItemTemplate>
                    <li><a href='<%#"newsdetail.aspx?id="+Eval("id")%>'>
                        <%#Eval("title")%>
                    </a></li>
                </ItemTemplate>
            </asp:DataList>
        </ul>
        <asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:decheatConnectionString %>"
            SelectCommand="SELECT id, topicid, headtitle, pretitle, title, titlecolor, titlefont, subtitle, newscontent, keyword, pagetype, autopagewordnumber, photos, Priority, newsfrom, sort, userid, username, time, subclassid, subclassname, mainclassid, mainclassname, hits, zhaiyao, xiangguan, url, [top], Score, Recommended, readstate, Delete_flag FROM dbo.Dyh_News where Delete_flag=0 order by subclassid ,time desc">
        </asp:SqlDataSource>
        <table style="width: 976px" cellpadding="0" cellspacing="0">
            <tr>
                <td style="width: 976px; text-align: right; font-size: 12pt; height: 25px;">
                    <asp:Label ID="Label7" runat="server" Text="当前页码为："></asp:Label>
                    [
                    <asp:Label ID="labPage" runat="server" Text="1"></asp:Label>
                    ]
                    <asp:Label ID="Label6" runat="server" Text="总页码为："></asp:Label>
                    [
                    <asp:Label ID="labBackPage" runat="server"></asp:Label>
                    ]<asp:LinkButton ID="lnkbtnOne" runat="server" Font-Underline="False" ForeColor="Red"
                        OnClick="lnkbtnOne_Click">第一页</asp:LinkButton>
                    <asp:LinkButton ID="lnkbtnUp" runat="server" Font-Underline="False" ForeColor="Red"
                        OnClick="lnkbtnUp_Click">上一页</asp:LinkButton>
                    <asp:LinkButton ID="lnkbtnNext" runat="server" Font-Underline="False" ForeColor="Red"
                        OnClick="lnkbtnNext_Click">下一页</asp:LinkButton>
                    <asp:LinkButton ID="lnkbtnBack" runat="server" Font-Underline="False" ForeColor="Red"
                        OnClick="lnkbtnBack_Click">最后一页</asp:LinkButton>
                </td>
            </tr>
        </table>
    </form>
</body>
</html>
